<!DOCTYPE html>
<html>

	<head>
		<meta charset="utf-8" />
		<title>会员列表</title>
		<link rel="stylesheet" href="__OEM__/css/iconfont.css" />
		<link rel="stylesheet" href="__OEM__/css/css.css" />
	</head>

	<body>
		{include file="public/header" /}
		<div class="index_conbox">
			<div class="index_content clearfix">
				{include file="public/lefter" /}
				<div class="right"><!--右侧内容-->
					<div class="rigtop">
						<span class="title">商圈审核</span>
					</div>
					<div class="indrig_con">
						<div class="zizh_conbox" style="padding-top: 20px;">
							<!--选项卡内容开始-->
							<div class="zizh_con_1">
								<form id="my_form" action="{:url('accounts/union_sh')}" method="post">
								<div class="shxx_row chax_row clearfix">
						           <div class="left">商圈名称：</div>
						            <div class="right clearfix">
						                <input type="text" name="store_name" placeholder="商圈名称" class="chax_input" />
						           </div>
						           <div class="shxx_row clearfix">
									<div class="left">操作：</div>
									<div class="right clearfix">
										<div id="htselect">
											<select name="state">
												<option value="">全部</option>
												<option value="2">已通过</option>
												<option value="1">等待审核</option>
											</select>
										</div>
									</div>
								</div>
						           <button type="submit" class="htcxbtn">查询</button>
						        </div>
						        
						       </form>
						       <div class="chax_conbox">
									<div class="chax_jiegnr">
										<table class="zizh_table1 zizh_table2">
											<thead>
												<tr>
													<th>商圈名称</th>
													<th>客户量</th>
													<th>联盟主</th>
													<th>电话</th>
													<th>商圈</th>
													<th>操作</th>
												</tr>
											</thead>
											<tbody id="tbody">
												{volist name="list" id="vo" empty="$empty"}
												<tr>
													<td>{$vo.name}</td>
													<td>{$vo.tel}</td>
													<td>{$vo.mobile}</td>
													<td>{$vo.tel}</td>
													<td>{$vo.sq_name}</td>
													<td>
														{if condition="$vo.state == 2"}
														<a class="gray" href="javascript:;" onclick="union_shenhe('{$vo.id}','1')">已通过,去冻结</a>
														{else /}
														<a href="javascript:;" onclick="union_shenhe('{$vo.id}','2')">等待审核,去审核</a>
														{/if}
													</td>
												</tr>
												{/volist}
											</tbody>
										</table>
										<div class="fenye" style="display: block;">
											{$list->render()}
										</div>
									</div>
								</div>
							</div>
						</div>

					</div>
				</div>
			</div>
		</div>
		{include file="public/footer" /}
	</body>
</html>
<script>
/*启用*/
function union_shenhe(id,lid) {
	layer.confirm('您确定要审核吗？', {
		btn: ['确定', '取消'] //按钮
	}, function() {
		$.ajax({
			url: "{:url('accounts/union_shenhe')}",
			data: {
				id:id,
				lid:lid
			},
			dataType: 'json',
			success: function(data) {
				layer.msg("成功", {
					icon: 1,
					time: 1000
				}, function() {
					location.href = "{:url('accounts/union_sh')}";
				});
			}
		})
	})
}
</script>